package com.example.elderlycare.dao.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Builder;
import lombok.Data;
import lombok.experimental.Tolerate;

import java.util.Date;

@Data
@TableName("elders")
@Builder
public class Elder {
    private Integer id;
    private Date deletedAt;
    private String name;
    private String number;
    private String phone;
    private Integer sex;
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date birthday;
    private Integer certificateId;
    @TableField(exist = false)
    private String certificateName;

    @Tolerate
    Elder() {
    }
}
